import { NextRequest, NextResponse } from 'next/server';
import { getServerSession } from './server/auth';
import { redirect } from 'next/navigation';

export async function middleware(request: NextRequest) {
  /*  const session = await getServerSession();
  if (session?.user == null) redirect('/api/auth/signin'); */

  return NextResponse.redirect(new URL('/api/auth/signin', request.url));
}

export const config = {
  matcher: '/dashboard/:path*',
};
